import request from '@/utils/request'

// 查询用户达人关联列表
export function listUserExpertInfo(query) {
  return request({
    url: '/system/userExpertInfo/list',
    method: 'get',
    params: query
  })
}

// 查询用户达人关联详细
export function getUserExpertInfo(id) {
  return request({
    url: '/system/userExpertInfo/' + id,
    method: 'get'
  })
}

// 新增用户达人关联
export function addUserExpertInfo(data) {
  return request({
    url: '/system/userExpertInfo',
    method: 'post',
    data: data
  })
}

// 修改用户达人关联
export function updateUserExpertInfo(data) {
  return request({
    url: '/system/userExpertInfo',
    method: 'put',
    data: data
  })
}

// 删除用户达人关联
export function delUserExpertInfo(id) {
  return request({
    url: '/system/userExpertInfo/' + id,
    method: 'delete'
  })
}

export function getAudit() {
  return request({
    url: '/system/userExpertInfo/getAudit',
    method: 'get'
  })
}

export function enableAudit(isAudit) {
  return request({
    url: '/system/userExpertInfo/enableAudit/' + isAudit,
    method: 'get'
  })
}


export function userAudit(data) {
  return request({
    url: '/system/userExpertInfo/userAudit',
    method: 'post',
    data: data
  })
}
